package test;

import java.util.Scanner;

public class Version1 {
  
  public static void main(String[] args){
	  Scanner in = new Scanner(System.in);
	  String str = in.nextLine();
	  String[] strs = str.split(",");
	  strs[strs.length-1]=strs[strs.length-1].replace("#", "");
	  sortString(strs);
	  for(String s:strs)
	  System.out.print(s+" ");
	  
  }
  
  private static void  sortString(String[] strs){
	  for(int i=0;i<strs.length;i++){
		  for(int j=i+1;j<strs.length;j++){
			  if(strs[i].compareTo(strs[j])>0){
				  String s = strs[i];
				  strs[i] = strs[j];
				  strs[j] = s;
			  }
		  }
		  
	  }
  }
	
}
